<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%--
  Created by IntelliJ IDEA.
  User: Wang Ziming
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>收藏</title>
</head>
<body>
    <div class="nav-coll">我的收藏</div>
    <hr>
    <%--引入了具体的收藏对象，以table形式组织--%>
    <table class="tab-coll" align="center" width="100%">
        <thead>
            <tr>
                <th>出游地</th>
                <th>收藏时间</th>
                <th>操作</th>
            </tr>
        </thead>

        <%--逆序展示出所有的收藏--%>
        <tbody width="100%" align="center">
            <c:forEach items="${collections}" var="collection">
                <tr>
                    <td>${collection.destinations}</td>
                    <td>${collection.time}</td>
                    <td><a href="/collection/deleteCollection?collectionId=${collection.collectionId}">删除</a></td>
                </tr>
            </c:forEach>
        </tbody>
    </table>
</body>
<style>
    .nav-coll{
        margin-top: 3%;
    }
    .tab-coll{

    }
</style>
</html>
